package jsyf.oa.entity.system;

import com.alibaba.fastjson.JSONObject;
import jsyf.oa.ientity.BaseEntity;

import javax.persistence.Entity;
import javax.persistence.Table;

/**
 * Created by jjx on 2018/3/19.
 */
@Entity
@Table(name = "T_WECHAT_FRIENDS_CONTACTS", schema = "oa", catalog = "")
public class WechatContactsEntity extends BaseEntity {

    private String userId;
    private String userName;
    private String screenshotsUrl;
    private String contacts;

    public String getUserId() {
        return userId;
    }

    public void setUserId(String userId) {
        this.userId = userId;
    }

    public String getUserName() {
        return userName;
    }

    public void setUserName(String userName) {
        this.userName = userName;
    }

    public String getScreenshotsUrl() {
        return screenshotsUrl;
    }

    public void setScreenshotsUrl(String screenshotsUrl) {
        this.screenshotsUrl = screenshotsUrl;
    }

    public String getContacts() {
        return contacts;
    }

    public void setContacts(String contacts) {
        this.contacts = contacts;
    }

    @Override
    public JSONObject getJSONObject() {
        JSONObject obj = new JSONObject();
        obj.put("ID", this.getId());
        obj.put("USER_ID", this.getUserId());
        obj.put("USER_NAME", this.getUserName());
        obj.put("CREATE_TIME", this.getCreateTime());
        obj.put("SCREENSHOTS_URL", this.getScreenshotsUrl());
        obj.put("CONTACTS", this.getContacts());
        obj.put("DEL_FLAG", this.getDelFlag());
        return obj;
    }

    @Override
    public String getTableName() {
        return "T_WECHAT_FRIENDS_CONTACTS";
    }

    @Override
    public JSONObject getJSONColumns() {
        JSONObject obj = new JSONObject();
        obj.put("ID", "id");
        obj.put("USER_ID", "userId");
        obj.put("USER_NAME", "userName");
        obj.put("CREATE_TIME", "createTime");
        obj.put("SCREENSHOTS_URL", "screenshotsUrl");
        obj.put("CONTACTS", "contacts");
        obj.put("DEL_FLAG", "delFlag");
        return obj;
    }
}
